package com.angel.activity;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;

public class QuitProgress {
	public  static final int EXIT_PROGRESS=0x0001;
	public  static final int CHANGE_PROGRESS=0x0002;
	private Context context;
	public QuitProgress(Context context){
		this.context=context;
	}
	public void exit(){
		Intent intent=new Intent(context,WelcomeActivity.class);
		intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
//		intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
		intent.putExtra("flag",EXIT_PROGRESS);
		context.startActivity(intent);
	}
	public void changeAccount(){
		Intent intent=new Intent(context,LoginActivity.class);
		intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
//		intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK);
//		intent.putExtra("flag",CHANGE_PROGRESS);
		context.startActivity(intent);
	}
}
